package com.aliyun.messagemgt.dto.base;

import com.aliyun.messagemgt.common.validation.ValidationGroups;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotBlank;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 基础表-接收组范围表
 * </p>
 *
 * @author wugongzi
 * @since 2021-09-28
 */
@Data
@EqualsAndHashCode(callSuper = false)
@ApiModel("接收组范围cmd")
public class BaseReceiveGroupRangeAddCmd implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "接收组ID，对应接收组主表ID",hidden = true)
    private Long groupId;

    @ApiModelProperty("范围类型 ORG-组织 POS-职位 ROLE-角色 USER-用户")
    @NotBlank(message = "范围类型为空",groups = {ValidationGroups.Insert.class})
    private String rangeType;

    @ApiModelProperty("范围主体ID")
    @NotBlank(message = "范围主体ID为空",groups = {ValidationGroups.Insert.class})
    private String rangeEntityId;

    @ApiModelProperty("创建人")
    private String creator;

    @ApiModelProperty(value = "修改时间",hidden = true)
    private LocalDateTime gmtModified = LocalDateTime.now();
}
